//
//  ContractMainViewController.m
//  OAProject
//
//  Created by yhj on 2017/2/22.
//  Copyright © 2017年 cdnunion. All rights reserved.
//  合同主界面

#import "ContractMainViewController.h"
#import "NotExamineViewController.h"
#import "DoneExamineViewController.h"


@interface ContractMainViewController ()

@end

@implementation ContractMainViewController

- (void)viewDidLoad {
    [super viewDidLoad];

    // 初始化样式
    [self initView];

    // 添加子控制器
    [self addChildVC];

     self.title=@"合同";

}

// 初始化样式
-(void)initView
{
    // 设置标题栏样式
    [self setUpTitleEffect:^(UIColor *__autoreleasing *titleScrollViewColor, UIColor *__autoreleasing *norColor, UIColor *__autoreleasing *selColor, UIFont *__autoreleasing *titleFont, CGFloat *titleHeight, CGFloat *titleWidth)
     {
         *titleScrollViewColor=[UIColor whiteColor];
         *norColor=BlackColor;
         *selColor=HexRGB(0x1E90FF);
         *titleWidth=APPW/2;
     }];

    // 设置下标
    [self setUpUnderLineEffect:^(BOOL *isUnderLineDelayScroll, CGFloat *underLineH, UIColor *__autoreleasing *underLineColor, BOOL *isUnderLineEqualTitleWidth) {
        *isUnderLineDelayScroll=YES;
        *underLineColor=HexRGB(0x1E90FF);
    }];
}

// 添加子控制器
-(void)addChildVC
{
    // 未审批
    NotExamineViewController *notExamineViewController=[NotExamineViewController new];
    notExamineViewController.title=@"未审批";
    [self addChildViewController:notExamineViewController];

    // 已审批
    DoneExamineViewController *doneExamineViewController=[DoneExamineViewController new];
    doneExamineViewController.title=@"已审批";
    [self addChildViewController:doneExamineViewController];
    
}

@end
